home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The World of Computer Software
/
The World of Computer Software.iso
/
faq-s.zip
/
MAIN.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1991-05-04
|
9KB
|
263 lines
{$R-,S-,I-,D-,F+,V-,B-,N-,O+ }
{$M 65500,0,0 }
unit main;
interface
uses crt,overlay,gamble,trivia,mainr1,
gentypes,modem,gensubs,subs1,subs2,userret,overret1,mainr2,
quotes,about,msg,configur,database,doors,email,filexfer,mycomman,voting,
mainmenu,gfiles,configrt,viewansi,nuv,getlogin;
procedure mainsysopcommands;
procedure quickmenu;
procedure mainmenuproc;
procedure breakout;
implementation
procedure mainsysopcommands;
var k,c:char;
q:integer;
begin
repeat
q:=menu ('Sysop','SYSOP','QTEANDUCIJSKVMFRZOXP?');
case q of
2:editoldspecs;
3:readerrlog;
4:addnews;
5:editnews;
6:delerrlog;
7:editusers;
8:settime;
9:infoformhunt;
10:showallforms;
11:viewsyslog;
12:delsyslog;
13:showallsysops;
14:makeuser;
15:readfeedback;
16:removeallforms;
17:zapspecifiedusers;
19:transfername;
20:searchphone;
21:begin
writeln('
C
╔═════════════════════════════════════╗H
s');
writeln('u
C║
Sysop Section
║H
s');
writeln('u
C╚═════════════════════════════════════╝HHC╔══
s');
writeln('u
═══════════════════════════════════╗HC║ [
A
]
s');
writeln('u
Add News
║HC║ [
C
s');
writeln('u
]
Change Time/Date
║HC║ [
s');
writeln('u
D
]
Delete Error Log
║H
s');
writeln('u
C║ [
E
]
Read Error Log
║
');
writeln('
1HC║ [
F
]
Feedback Section
s');
writeln('u
║1HC║ [
I
]
Search for Infoform
s');
writeln('u
╔═════════════════════════════════════╗1HC
║
s');
writeln('u
[
J
]
Show all Infoforms
║ [
Q
s');
writeln('u
]
Quit
║1HC
s');
writeln('u
║ [
K
]
Delete System Log
║ [
s');
writeln('u
R
]
Delete Infoforms
║1HC
s');
writeln('u
║ [
M
]
Make/Create User
║ [
s');
writeln('u
S
]
Read System Log
║1HC
s');
writeln('u
║ [
N
]
News Editor
║ [
s');
writeln('u
T
]
Edit Told Specifications
║1HC
s');
writeln('u
║ [
O
]
Modify Conference(s)
║ [
s');
writeln('u
U
]
Edit User(s)
║1HC
s');
writeln('u
║ [
P
]
Search for Phone #
║ [
s');
writeln('u
V
]
Show all Sysops
║1HC
s');
writeln('u
╚════════════════════════════
║ [
X
]
T
s');
writeln('u
ransfer User
║1HC║ [
Z
]
s');
writeln('u
Zap Specified User(s)
║1HC║ [
s');
writeln('u
?
]
View This Menu
║1H
A');
writeln('
C╚═════════════════════════════════════╝
');
writeln;
pause;
end;
end
until (q=1) or hungupon
end;
procedure mainmenuproc;
var b:boolean;
c:char;
cnt,q:integer;
begin
repeat
if fromdoor and (returnto='D') then doorsmenu;
cursection:=mainsysop;
randomquote;
echoit:=true;
q:=menu ('Main','MAIN','ABCDEFGHIJKLMNOPQRSTUVWXYZ+-!&$%@*./?');
writeln;
case q of
1:aboutthisbbs;
2:bbslist;
3:summonsysop;
4:datamenu;
5:emailmenu;
6:feedback;
7:offfaq;
9:begin
writeln;
writestr ('Which Info-Form would you like to fill out? [#1-5]: *');
if (valu(input)>0) or (valu(input)<6) then
infoform (valu(input)) else
writeln (^M'Invalid Info-Form Number!'^M);
end;
10:if usegambling then begin;
credits:=0;
game;
end;
11:begin clearscr; configure; end;
12:listusers;
13:begin
changecon('M');
messagemenu;
end;
14:printnews;
15:doorsmenu;
16:gfilesection;
{17:begin
writestr (^R'Begin Global Newscan? [y/n]: '^U'*'); if yes then begin
changecon('M'); messagemenu; newscanall;
changecon('X'); udsection; newscanall;
end else exit;
end;}
17{18}:quotemenu;
19:showsystemstatus;
20:begin
changecon('X');
udsection;
end;
18{21}:playTrivia;
21:if usenuv then newvotex else write (^M'New User Voting not configured in setup.'^M);
22:votingbooth(false);
23:showlastcallers;
24:timebank;
25:begin
show_all_info(textfiledir+'UserStat',getlastcaller,cnt);
pause;
end;
26:setlastcall;
27:changepwd;
28:quickmenu;
29:requestraise;
30:showad;
31:donations;
32:mainsysopcommands;
33:viewansiscreens;
34:showcredits;
35:if matrixtype>0 then begin
writestr ('Go back to Gateway? *');
if yes then begin getloginproc; exit; end;
end;
36:begin
if ansigraphics in urec.config then begin
cursor (false);
clearscr;
ansi_window (29,1,51,3);
movexy (33,2); write (^S'[ Main Section ]');
ansi_window (4,5,26,18);
write_menu (6,6,'A','Information');
write_menu (6,7,'B','BBS Listings');
write_menu (6,8,'C','Page the Sysop');
write_menu (6,9,'D','Databases');
write_menu (6,10,'E','Electronic Mail');
write_menu (6,11,'F','Feedback');
write_menu (6,12,'G','Log off of BBS');
write_menu (6,13,'I','Infoforms');
write_menu (6,14,'J','Games/Gambling');
write_menu (6,15,'K','User Config');
write_menu (6,16,'L','List Users');
write_menu (6,17,'M','Message Section');
ansi_window (29,5,51,18);
write_menu (31,6,'N','Read News');
write_menu (31,7,'O','Online Doors');
write_menu (31,8,'P','G-Files Section');
write_menu (31,9,'Q','Quotes Section');
write_menu (31,10,'R','Trivia Section');
write_menu (31,11,'S','System Stats');
write_menu (31,12,'T','Transfer Section');
write_menu (31,13,'V','Voting Section');
write_menu (31,14,'W','Last Callers');
write_menu (31,15,'X','Time Bank');
write_menu (31,16,'Y','User Statistics');
write_menu (31,17,'Z','Change Last Call');
ansi_window (54,5,76,18);
write_menu (56,6,'!','Raise Request');
write_menu (56,7,'$','Donation Info');
write_menu (56,8,'%','Sysop Commands');
write_menu (56,9,'&','View BBS Ad');
write_menu (56,10,'*','Welcome Screens');
write_menu (56,11,'-','Quick Section');
write_menu (56,12,'+','Change Password');
write_menu (56,13,'.','FAQ Credits');
write_menu (56,14,'/','Return to Gateway');
write_menu (56,15,'/O','Log off FAST!');
write_menu (56,16,'^R','Last Command');
write_menu (56,17,'?','View This Menu');
movexy (1,20);
cursor (true);
pause;
end else printfile (textfiledir+'MAINM');
end;
end
until hungupon
end;
procedure quickmenu;
var i:char;
begin
repeat
buflen:=1;
writestr (^P'['^R'Quick Section'^P'] ['^R+strr(timeleft)+^P']'^S': '^U'*');
i:=upcase(input[1]);
case i of
'C':summonsysop;
'G','O':offfaq;
'X':begin changecon('X');
udsection;
end;
'M':begin changecon('M');
messagemenu;
end;
'E':emailmenu;
'F':feedback;
'?':begin
writeln (^M' - FAQ Quick Section -'^M);
writeln ('[C]: Page the Sysop [E]: Email Section');
writeln ('[F]: Feedback [G]: Log off');
writeln ('[M]: Message Bases [O]: Log off');
writeln ('[Q]: Quit [X]: Xfer Section');
writeln ('[?]: This Menu'^M);
end;
end;
until (upcase(i)='Q') or hungupon;
end;
procedure breakout;
begin
if (erroraddr=nil) and (exitcode=e_controlbreak) then begin
textcolor (7);
textbackground (0);
updateuserstats (false);
writeln (direct,'Break:');
writereturnbat;
ensureclosed;
window (1,1,80,25);
gotoxy (1,25);
clreol;
if not carrier then dontanswer
end;
doneexitproc
end;
{$F-}
begin
addexitproc (@breakout)
end.